package composite;

/**
 * @author : DuJiabao
 * @Date : 2021/3/3 18:44
 * @Project : design-pattern
 * @File : null.java
 * @Desc :
 */
public class Department extends OrganizationComponent {
  public Department() {
  }

  public Department(String name, String desc) {
    super(name, desc);
  }

  @Override
  public void add(OrganizationComponent organizationComponent) {
    throw new UnsupportedOperationException();
  }

  @Override
  public void remove(OrganizationComponent organizationComponent) {
    throw new UnsupportedOperationException();
  }

  @Override
  public void print() {
    System.out.println(super.getName() + " " + super.getDesc());
  }
}
